<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core"  prefix="c"%>
<%@ taglib uri="http://java.sun.com/jstl/fmt_rt" prefix="fmt" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>Login</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="" />
    <meta name="keywords" content="" />
    <meta name="author" content="" />
    <!-- Facebook and Twitter integration -->
    <meta property="og:title" content=""/>
    <meta property="og:image" content=""/>
    <meta property="og:url" content=""/>
    <meta property="og:site_name" content=""/>
    <meta property="og:description" content=""/>
    <meta name="twitter:title" content="" />
    <meta name="twitter:image" content="" />
    <meta name="twitter:url" content="" />
    <meta name="twitter:card" content="" />

  <%--  <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,700" rel="stylesheet">--%>

    <!-- Animate.css -->
    <link rel="stylesheet" href="resources/css/animate.css">
    <!-- Icomoon Icon Fonts-->
    <link rel="stylesheet" href="resources/css/icomoon.css">
    <!-- Themify Icons-->
    <link rel="stylesheet" href="resources/css/themify-icons.css">
    <!-- Bootstrap  -->
    <link rel="stylesheet" href="resources/css/bootstrap.css">

    <!-- Magnific Popup -->
    <link rel="stylesheet" href="resources/css/magnific-popup.css">

    <!-- Owl Carousel  -->
    <link rel="stylesheet" href="resources/css/owl.carousel.min.css">
    <link rel="stylesheet" href="resources/css/owl.theme.default.min.css">

    <!-- Theme style  -->
    <link rel="stylesheet" href="resources/css/style.css">

    <!-- Modernizr JS -->
    <script src="resources/js/modernizr-2.6.2.min.js"></script>
    <!-- FOR IE9 below -->
    <!--[if lt IE 9]>
    <script src="resources/js/respond.min.js"></script>
    <![endif]-->

    <script type="text/javascript" src="resources/js/jquery-1.8.2.min.js"></script>
</head>
<style>
    span{
        color:red;
    }
</style>
<body>

<div class="gtco-loader"></div>

<div id="page">


    <div class="page-inner">
        <nav class="gtco-nav" role="navigation">
            <div class="gtco-container">

                <div class="row">
                    <div class="col-sm-4 col-xs-12">
                        <div id="gtco-logo"><a href="login.jsp">每日乐享 <em>.</em></a></div>
                    </div>
                    <div class="col-xs-8 text-right menu-1">
                        <ul>
                            <li><a href="features.html">NBA</a></li>
                            <li><a href="tour.html">读书</a></li>
                            <li class="has-dropdown">
                                <a href="#">财经</a>
                                <ul class="dropdown">
                                    <li><a href="#">Web Design</a></li>
                                    <li><a href="#">eCommerce</a></li>
                                    <li><a href="#">Branding</a></li>
                                    <li><a href="#">API</a></li>
                                </ul>
                            </li>
                            <li><a href="pricing.html">娱乐</a></li>
                            <li><a href="contact.html">军事</a></li>
                            <li class="btn-cta"><a href="#"><span>时事</span></a></li>
                        </ul>
                    </div>
                </div>

            </div>
        </nav>

        <header id="gtco-header" class="gtco-cover" role="banner" style="background-image: url(resources/images/img_4.jpg)">
            <div class="overlay"></div>
            <div class="gtco-container">
                <div class="row">
                    <div class="col-md-12 col-md-offset-0 text-left">
                        <div class="row row-mt-15em">
                            <div class="col-md-7 mt-text animate-box" data-animate-effect="fadeInUp">
                                <!--<span class="intro-text-small">欢迎来到每日乐享</span>-->
                                <h1>欢迎来到每日乐享.</h1>
                            </div>
                            <div class="col-md-4 col-md-push-1 animate-box" data-animate-effect="fadeInRight">
                                <div class="form-wrap">
                                    <div class="tab">
                                        <ul class="tab-menu">
                                            <li class="active gtco-first"><a href="#" data-tab="signup">注册</a></li>
                                            <li class="gtco-second"><a href="#" data-tab="login">登录</a></li>
                                        </ul>
                                        <div class="tab-content">
                                            <div class="tab-content-inner active" data-content="signup">
                                                <form action="${pageContext.request.contextPath }/admin/register">
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="username">用户名</label>
                                                            <input type="text" class="form-control" id="username" name="loginName"><span id="spanUname"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="password">密码</label>
                                                            <input type="password" class="form-control" id="password" name="loginPwd"><span id="spanpass"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="password">再次输入密码</label>
                                                         <input type="password" class="form-control" id="password2" name="password2"><span id="spantwoPass"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="username">真实姓名</label>
                                                            <input type="text" class="form-control"  name="username"><span id="name"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="username">电子邮箱</label>
                                                            <input type="email " class="form-control"  name="email" ><span id="email2"></span>
                                                        </div>
                                                    </div>

                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <input type="submit" class="btn btn-primary" value="现在注册 ">
                                                        </div>
                                                    </div>
                                                </form>
                                            </div>
                                            <div class="tab-content-inner" data-content="login">
                                                <form action="#">
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="username">用户名</label>
                                                            <input type="text" class="form-control" name="dengluming"><span id="dengluming"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <label for="password">密码</label>
                                                            <input type="password" class="form-control" name="mima"><span id="mima"></span>
                                                        </div>
                                                    </div>
                                                    <div class="row form-group">
                                                        <div class="col-md-12">
                                                            <input type="submit" class="btn btn-primary" value="登录">
                                                        </div>
                                                    </div>
                                                </form>
                                            </div>

                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </header>





        <footer id="gtco-footer" role="contentinfo">
            <div class="gtco-container">
                <div class="row row-p	b-md">

                    <div class="col-md-4">
                        <div class="gtco-widget">
                            <h3>关于 <span class="footer-logo">每日乐享</span>.<span></span></h3>
                            <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Tempore eos molestias quod sint ipsum possimus temporibus officia iste perspiciatis consectetur in fugiat repudiandae cum. Totam cupiditate nostrum ut neque ab?</p>
                        </div>
                    </div>

                    <div class="col-md-4 col-md-push-1">
                        <div class="gtco-widget">
                            <h3>链接</h3>
                            <ul class="gtco-footer-links">
                                <li><a href="#">知识库</a></li>
                                <li><a href="#">职业生涯</a></li>
                                <li><a href="#">服务条款</a></li>
                                <li><a href="#">隐私政策</a></li>
                            </ul>
                        </div>
                    </div>

                    <div class="col-md-4">
                        <div class="gtco-widget">
                            <h3>进入 触觉</h3>
                            <ul class="gtco-quick-contact">
                                <li><a href="#"><i class="icon-phone"></i> +1 234 567 890</a></li>
                                <li><a href="#"><i class="icon-mail2"></i> info@</a></li>
                                <li><a href="#"><i class="icon-chat"></i> 现场聊天</a></li>
                            </ul>
                        </div>
                    </div>

                </div>

                <div class="row copyright">
                    <div class="col-md-12">
                        <p class="pull-left">
                            <small class="block">Copyright &copy; 2016.Company name All rights reserved.</small>
                        </p>
                        <p class="pull-right">
                        <ul class="gtco-social-icons pull-right">
                            <li><a href="#"><i class="icon-twitter"></i></a></li>
                            <li><a href="#"><i class="icon-facebook"></i></a></li>
                            <li><a href="#"><i class="icon-linkedin"></i></a></li>
                            <li><a href="#"><i class="icon-dribbble"></i></a></li>
                        </ul>
                        </p>
                    </div>
                </div>

            </div>
        </footer>
    </div>

</div>

<div class="gototop js-top">
    <a href="#" class="js-gotop"><i class="icon-arrow-up"></i></a>
</div>
<script type="text/javascript">
    $(document).ready(function(){
        $("[name=loginName]").blur(function(){
            var name = $(this).val();
            if(name==""){
                $("#spanUname").html("用户名不能为空");
            }else{
                $("#spanUname").html("");
            }
        });

        $("[name=loginPwd]").blur(function(){
            var name = $(this).val();
            var patt1 = new RegExp("^[0-9a-zA-Z]{6,16}$");
            if(name==""){
                $("#spanpass").html("密码不能为空");
            }
            else if(!patt1.test(name)){
                $("#spanpass").html("用户名长度在6-20之间，由字母和数字组成");

            }
            else{
                $("#spanpass").html("");
            }
        });
        $("[name=password2]").blur(function(){
            var name = $(this).val();
            var name2=$("[name=loginPwd]").val();
            if(name==""){
                $("#spantwoPass").html("请再次输入密码");
                return false;
            }else if(name2!=name){
                $("#spantwoPass").html("请保持密码一致");
                return false;
            }else{
                $("#spantwoPass").html("");

            }
        });
        $("[name=username]").blur(function(){
            var name = $(this).val();
            if(name==""){
                $("#name").html("真实姓名不能为空");
            }else{
                $("#name").html("");
            }
        });

            $("[name=email]").blur(function(){
                var name = $(this).val();
                var myreg = /^([\.a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-])+/;
                if(name==""){
                    $("#email2").html("邮箱不能为空");
                    return false;
                }else if(!myreg.test(name)){
                    $("#email2").html("请输入有效的邮箱地址！");
                    return false;
                }else{
                    $("#email2").html("");
                }
            });
            $("[name=dengluming]").blur(function(){
                var name=$(this).val();
                 if(name==""){
                    $("#dengluming").html("请输入用户名");
                    return false;
                }
                else {
                     $("#dengluming").html("");

                 }
            })
        $("[name=mima]").blur(function(){
            var name=$(this).val();
            var patt1 = new RegExp("^[0-9a-zA-Z]{6,16}$");
            if(name==""){
                $("#mima").html("请输入密码");
                return false;
            }else if(!patt1.test(name)){
                $("#mima").html("用户名长度在6-20之间，由字母和数字组成");
                return false;

            }
            else {
                $("#mima").html("");

            }
        })

    });
</script>
<!-- jQuery -->
<script src="resources/js/jquery.min.js"></script>
<!-- jQuery Easing -->
<script src="resources/js/jquery.easing.1.3.js"></script>
<!-- Bootstrap -->
<script src="resources/js/bootstrap.min.js"></script>
<!-- Waypoints -->
<script src="resources/js/jquery.waypoints.min.js"></script>
<!-- Carousel -->
<script src="resources/js/owl.carousel.min.js"></script>
<!-- countTo -->
<script src="resources/js/jquery.countTo.js"></script>
<!-- Magnific Popup -->
<script src="resources/js/jquery.magnific-popup.min.js"></script>
<script src="resources/js/magnific-popup-options.js"></script>
<!-- Main -->
<script src="resources/js/main.js"></script>

</body>
</html>

